package org.krishna.model;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Transient;

@Entity
@Table(name = "student_details")
public class Student implements Serializable{
	
	/** The Constant serialVersionUID. */
	@Transient
	private static final long serialVersionUID = -7660824605183781430L;

	@Id
	@GeneratedValue
	@Column(name = "student_id")
	private long studentId;

	@Column(name = "student_name")
	private String studentName;

	@ManyToOne
	@JoinColumn(name = "parent_id")
	private Login login;

	public Student(){
		
	}
	
	public Student(String studentName) {
		this.studentName = studentName;
		
	}

	public long getStudentId() {
		return studentId;
	}

	public void setStudentId(long studentId) {
		this.studentId = studentId;
	}

	public String getStudentName() {
		return studentName;
	}

	public void setStudentName(String studentName) {
		this.studentName = studentName;
	}

	public Login getLogin() {
		return login;
	}

	public void setLogin(Login login) {
		this.login = login;
	}
}
